﻿using System.Data;
using DAL;

namespace BLL
{
    public class SalaryYearBiz
    {
        SalaryYearDao salaryYearDao = new SalaryYearDao();
        //年终奖
        public DataTable GetList(string serWord, string strYear, string deptID, string setsID)
        {
            return salaryYearDao.GetList(serWord, strYear, deptID,setsID);

        }
        public DataTable GetOut(string serWord, string strYear, string deptID, string setsID)
        { return salaryYearDao.GetOut(serWord, strYear, deptID, setsID); }


        public bool Delete(string salYear, string empCode, string setsID)
        {
            return salaryYearDao.Delete( salYear,empCode, setsID);
        }
        public bool IsApply(string salYear, string setsID)
        {
            return salaryYearDao.IsApply(salYear, setsID);
        }
        //根据SalID 获取一条年终奖
        public DataTable GetYearEnd(string salID)
        { return salaryYearDao.GetYearEnd(salID); }
        public bool IsExist(string salYear, string setsID)
        {
            return salaryYearDao.IsExist(salYear,setsID);
        }
        //判断 某年 某个工号有没有生成年终奖
        public bool IsExist(string salYear, string empCode, string setsID)
        {
            return salaryYearDao.IsExist(salYear, empCode,setsID);
        }
        //把年终奖写入到工资表
        public bool CopyYearToSalTable(string fromYear, string toYear, string toMonth, string setsID)
        {
            return salaryYearDao.CopyYearToSalTable(fromYear, toYear, toMonth, setsID);
        }

        //生成年终奖
        public bool CreateYear(string setsID, string strYear)
        {
            return salaryYearDao.CreateYear(setsID, strYear);
        }
    }
}
